package cn.zcib.tms.model;

import java.util.ArrayList;
import java.util.List;

public class SourceExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public SourceExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andSoIdIsNull() {
            addCriterion("so_id is null");
            return (Criteria) this;
        }

        public Criteria andSoIdIsNotNull() {
            addCriterion("so_id is not null");
            return (Criteria) this;
        }

        public Criteria andSoIdEqualTo(Integer value) {
            addCriterion("so_id =", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdNotEqualTo(Integer value) {
            addCriterion("so_id <>", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdGreaterThan(Integer value) {
            addCriterion("so_id >", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("so_id >=", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdLessThan(Integer value) {
            addCriterion("so_id <", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdLessThanOrEqualTo(Integer value) {
            addCriterion("so_id <=", value, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdIn(List<Integer> values) {
            addCriterion("so_id in", values, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdNotIn(List<Integer> values) {
            addCriterion("so_id not in", values, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdBetween(Integer value1, Integer value2) {
            addCriterion("so_id between", value1, value2, "soId");
            return (Criteria) this;
        }

        public Criteria andSoIdNotBetween(Integer value1, Integer value2) {
            addCriterion("so_id not between", value1, value2, "soId");
            return (Criteria) this;
        }

        public Criteria andSoCateIsNull() {
            addCriterion("so_cate is null");
            return (Criteria) this;
        }

        public Criteria andSoCateIsNotNull() {
            addCriterion("so_cate is not null");
            return (Criteria) this;
        }

        public Criteria andSoCateEqualTo(Integer value) {
            addCriterion("so_cate =", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateNotEqualTo(Integer value) {
            addCriterion("so_cate <>", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateGreaterThan(Integer value) {
            addCriterion("so_cate >", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateGreaterThanOrEqualTo(Integer value) {
            addCriterion("so_cate >=", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateLessThan(Integer value) {
            addCriterion("so_cate <", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateLessThanOrEqualTo(Integer value) {
            addCriterion("so_cate <=", value, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateIn(List<Integer> values) {
            addCriterion("so_cate in", values, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateNotIn(List<Integer> values) {
            addCriterion("so_cate not in", values, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateBetween(Integer value1, Integer value2) {
            addCriterion("so_cate between", value1, value2, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoCateNotBetween(Integer value1, Integer value2) {
            addCriterion("so_cate not between", value1, value2, "soCate");
            return (Criteria) this;
        }

        public Criteria andSoAreaIsNull() {
            addCriterion("so_area is null");
            return (Criteria) this;
        }

        public Criteria andSoAreaIsNotNull() {
            addCriterion("so_area is not null");
            return (Criteria) this;
        }

        public Criteria andSoAreaEqualTo(String value) {
            addCriterion("so_area =", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaNotEqualTo(String value) {
            addCriterion("so_area <>", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaGreaterThan(String value) {
            addCriterion("so_area >", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaGreaterThanOrEqualTo(String value) {
            addCriterion("so_area >=", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaLessThan(String value) {
            addCriterion("so_area <", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaLessThanOrEqualTo(String value) {
            addCriterion("so_area <=", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaLike(String value) {
            addCriterion("so_area like", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaNotLike(String value) {
            addCriterion("so_area not like", value, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaIn(List<String> values) {
            addCriterion("so_area in", values, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaNotIn(List<String> values) {
            addCriterion("so_area not in", values, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaBetween(String value1, String value2) {
            addCriterion("so_area between", value1, value2, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoAreaNotBetween(String value1, String value2) {
            addCriterion("so_area not between", value1, value2, "soArea");
            return (Criteria) this;
        }

        public Criteria andSoNameIsNull() {
            addCriterion("so_name is null");
            return (Criteria) this;
        }

        public Criteria andSoNameIsNotNull() {
            addCriterion("so_name is not null");
            return (Criteria) this;
        }

        public Criteria andSoNameEqualTo(String value) {
            addCriterion("so_name =", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameNotEqualTo(String value) {
            addCriterion("so_name <>", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameGreaterThan(String value) {
            addCriterion("so_name >", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameGreaterThanOrEqualTo(String value) {
            addCriterion("so_name >=", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameLessThan(String value) {
            addCriterion("so_name <", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameLessThanOrEqualTo(String value) {
            addCriterion("so_name <=", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameLike(String value) {
            addCriterion("so_name like", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameNotLike(String value) {
            addCriterion("so_name not like", value, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameIn(List<String> values) {
            addCriterion("so_name in", values, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameNotIn(List<String> values) {
            addCriterion("so_name not in", values, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameBetween(String value1, String value2) {
            addCriterion("so_name between", value1, value2, "soName");
            return (Criteria) this;
        }

        public Criteria andSoNameNotBetween(String value1, String value2) {
            addCriterion("so_name not between", value1, value2, "soName");
            return (Criteria) this;
        }

        public Criteria andSoAddressIsNull() {
            addCriterion("so_address is null");
            return (Criteria) this;
        }

        public Criteria andSoAddressIsNotNull() {
            addCriterion("so_address is not null");
            return (Criteria) this;
        }

        public Criteria andSoAddressEqualTo(String value) {
            addCriterion("so_address =", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressNotEqualTo(String value) {
            addCriterion("so_address <>", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressGreaterThan(String value) {
            addCriterion("so_address >", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressGreaterThanOrEqualTo(String value) {
            addCriterion("so_address >=", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressLessThan(String value) {
            addCriterion("so_address <", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressLessThanOrEqualTo(String value) {
            addCriterion("so_address <=", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressLike(String value) {
            addCriterion("so_address like", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressNotLike(String value) {
            addCriterion("so_address not like", value, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressIn(List<String> values) {
            addCriterion("so_address in", values, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressNotIn(List<String> values) {
            addCriterion("so_address not in", values, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressBetween(String value1, String value2) {
            addCriterion("so_address between", value1, value2, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoAddressNotBetween(String value1, String value2) {
            addCriterion("so_address not between", value1, value2, "soAddress");
            return (Criteria) this;
        }

        public Criteria andSoPhoneIsNull() {
            addCriterion("so_phone is null");
            return (Criteria) this;
        }

        public Criteria andSoPhoneIsNotNull() {
            addCriterion("so_phone is not null");
            return (Criteria) this;
        }

        public Criteria andSoPhoneEqualTo(String value) {
            addCriterion("so_phone =", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneNotEqualTo(String value) {
            addCriterion("so_phone <>", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneGreaterThan(String value) {
            addCriterion("so_phone >", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneGreaterThanOrEqualTo(String value) {
            addCriterion("so_phone >=", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneLessThan(String value) {
            addCriterion("so_phone <", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneLessThanOrEqualTo(String value) {
            addCriterion("so_phone <=", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneLike(String value) {
            addCriterion("so_phone like", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneNotLike(String value) {
            addCriterion("so_phone not like", value, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneIn(List<String> values) {
            addCriterion("so_phone in", values, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneNotIn(List<String> values) {
            addCriterion("so_phone not in", values, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneBetween(String value1, String value2) {
            addCriterion("so_phone between", value1, value2, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoPhoneNotBetween(String value1, String value2) {
            addCriterion("so_phone not between", value1, value2, "soPhone");
            return (Criteria) this;
        }

        public Criteria andSoImageIsNull() {
            addCriterion("so_image is null");
            return (Criteria) this;
        }

        public Criteria andSoImageIsNotNull() {
            addCriterion("so_image is not null");
            return (Criteria) this;
        }

        public Criteria andSoImageEqualTo(String value) {
            addCriterion("so_image =", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageNotEqualTo(String value) {
            addCriterion("so_image <>", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageGreaterThan(String value) {
            addCriterion("so_image >", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageGreaterThanOrEqualTo(String value) {
            addCriterion("so_image >=", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageLessThan(String value) {
            addCriterion("so_image <", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageLessThanOrEqualTo(String value) {
            addCriterion("so_image <=", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageLike(String value) {
            addCriterion("so_image like", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageNotLike(String value) {
            addCriterion("so_image not like", value, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageIn(List<String> values) {
            addCriterion("so_image in", values, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageNotIn(List<String> values) {
            addCriterion("so_image not in", values, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageBetween(String value1, String value2) {
            addCriterion("so_image between", value1, value2, "soImage");
            return (Criteria) this;
        }

        public Criteria andSoImageNotBetween(String value1, String value2) {
            addCriterion("so_image not between", value1, value2, "soImage");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}